package java基础知识.javaIO流;

import java流相关.PrintAndScannerStream;

import java.io.*;
import java.util.Scanner;

/**
 * @author coderFu
 * @create 2022/3/11
 * java 的IO 流
 */
public class CoderIO {

    public static void main(String[] args) throws FileNotFoundException {

        // 输入流 输出流

        PrintAndScannerStream scannerStream = new PrintAndScannerStream();

        OutputStream out;
        File file;
        file = new File("ada");
        out = new FileOutputStream(file);
        Scanner sc = new Scanner(System.in);
        while (sc.hasNextLine()){
            String s = sc.nextLine();
            if ("quit".equals(sc.nextLine())){
                break;
            }
            System.out.println(s);
        }

        // 

        try (PrintStream printStream = new PrintStream(out)) {

        }
    }
}
